'use client';
import { useRouter } from 'next/navigation';

const LogoutButton = ({ children }) => {
    const router = useRouter();
    const onClick = async () => {
        // await signOut({
        //     redirectTo: '/'
        // });
        router.push('/');
    };
    return (
        <span onClick={onClick} className="cursor-pointer">
            {children}
        </span>
    );
};

export default LogoutButton;
